package com.starinside.wp.domain.familyTest;

import com.starinside.wp.domain.Domain;
import lombok.Data;
import org.hibernate.annotations.GenericGenerator;

import javax.persistence.*;
import java.util.Date;
import java.util.List;

@Data
@Entity
@Table(name = "m_observation_task")
public class TestStoreObsTask extends Domain {
    @Column
    Integer testStoreId;

    @Column
    String childrenId;

    @Column
    Byte month;

    @Column
    String title;

    @Column
    String uploadFiles;

    @Column
    Byte fileType;

    @Column
    String image;

    @Column
    String video;

    @Column
    Integer sum;

    @Transient
    List<TestStoreObsPointScore> scores;

    public static TestStoreObsTask of(Integer testStoreId, String childrenId, Byte month, String title, String uploadFiles, Byte fileType, String image, String video) {
        TestStoreObsTask task = new TestStoreObsTask();
        task.testStoreId = testStoreId;
        task.childrenId = childrenId;
        task.month = month;
        task.title = title;
        task.uploadFiles = uploadFiles;
        task.fileType = fileType;
        task.image = image;
        task.video = video;
        return task;
    }
}
